<?php
if (!defined('INDEX')) {
	exit ('Access Denied');
}

$parameter=act_wap_tixian();
extract($parameter);
if ($webset['tixian']['level'] > 0 && $webset['tixian']['level'] > $dduser['level']) {
		jump(-1, '系统检测到您还没有购物记录，不能申请提取');
	}
include(TPLPATH.'/inc/header_3.tpl.php');

?>
<script>
<?php if($dduser['alipay']=='' || $dduser['realname']==''){?>
alert('请先设置基本信息','<?=wap_l(MOD,'set')?>');
<?php }?>

function cbCheckForm(input,$form){
	var url='<?=wap_l(MOD,ACT)?>';
	url=ddJoin(url,input);
	$('#tijiao').val('提交中...');
	$.ajax({
		url: url,
		dataType:'jsonp',
		jsonp:"callback",
		success: function(data){
			if(data.s==1){
				alert('提取完成，等待管理员审核','<?=wap_l(MOD,'index')?>');
			}
			else{
				alert(data.r);
			}
		}
	});
	return false;
}
</script> 
   <div class="admin_xfl">
                    <ul>
            <li><a href="<?=wap_l('user','tixian',array('type'=>'1'))?>"  <?php if($type=='1'){?>class="on"<?php }?>><?=TBMONEY?>提现</a> </li>
            <li > <a href="<?=wap_l('user','tixian',array('type'=>'2'))?>" <?php if($type=='2'){?>class="on"<?php }?>>余额提现</a> </li>
            <li > <a href="<?=wap_l('user','mingxi',array('do'=>'out'))?>" <?php if($do=='out'){?>class="on"<?php }?>>提现明细</a> </li>
                    </ul>
              	</div>
   <div class="p15" style="margin-top:-35px">
  <div class="register">
 	 <form onSubmit="return checkForm($(this),cbCheckForm)" action="">
			 <table border="0" width="100%" cellpadding="0" cellspacing="0" >
                        <?php if($type==1){?>   
						 <tr height="20">
                            <td  align="left"></td></tr>
                          <tr height="40">
                            <td width="230" align="left" class="ddinput">可提<?=TBMONEY?>：<font color="#FF0000"><B>
                            <?=$dduser['jifenbao'].$webset['TBMONEY']?></b></font> <?=TBMONEY?></td></tr>
		
						  <tr height="40">
                            <td  height="35" align="left" class="ddinput">提取要求    <span style="font-size:16px">（最低提取：<font color="#FF0000"><B><?=$webset['tixian']['tblimit']?></b></font> <?=TBMONEY?>）</span></td></tr>
							 
						  <tr height="40">
                            <td  height="35" align="left">填写提取数量</td></tr>
		 <tr>
                            <td align="left"><input id="jifenbao" type="text" class="ddinput"  name="jifenbao" placeholder="最低提取<?=$webset['tixian']['tblimit']?><?=TBMONEY?>" value="" dd-type="num" dd-required /></td>
                          </tr>
                        
						  <tr height="40">
                            <td  height="35" align="left">会员登陆密码</td></tr>
		<tr height="40">
                            <td align="left"><input id="ddpassword" name="ddpassword"  class="ddinput" value="" placeholder="输入登录密码" dd-required type="password"></td>
                          </tr>
                          <tr height="40">
                            <td  height="35" align="left">说明</td></tr>
		<tr height="40">
                            <td align="left"><input id="remark" name="remark" class="ddinput" value="" placeholder="特别说明，没有请留空" type="text"></td>
                          </tr>
						  <tr height="40">
                            <td height="90" colspan="3" align="left">
<input type="hidden" name="act" value="tixian" /><input type="hidden" name="type" value="1" /><input type="hidden" name="sub" value="1" />
<input type="hidden" name="code_uid" value="<?=$dduser['code_uid']?>" /><input type="hidden" name="pwd" value="<?=$dduser['pwd']?>" />
<input type="submit" value="提 交"  class="register_dl"/></td>
                          </tr>
						 <?php }else{?>
						  
						 <tr height="20">
                            <td  align="left"></td></tr>
                          <tr height="40">
                            <td align="left" class="ddinput">现有余额：<font color="#FF0000"><B>
                            <?=$dduser['money'].''?></b></font> 元</td></tr>
		
						  <tr height="40">
                            <td  height="35" align="left" class="ddinput"> 提取要求 <span style="font-size:16px">（最低提取：<font color="#FF0000"><B><?=$webset['tixian']['limit']?></b></font> 元）</span></td></tr> <tr height="40">
                            <td  height="35" align="left">填写提取数量</td></tr>
		 <tr>
		 <tr>
                            <td align="left"><input id="money" type="text" name="money"  class="ddinput" placeholder="最低提现<?=$webset['tixian']['limit']?>元" value="" dd-type="num" dd-required /></td>
                          </tr>
						  <tr height="40">
                            <td  height="35" align="left">登陆密码</td></tr>
		<tr height="40">
                            <td align="left"><input id="ddpassword" name="ddpassword" class="ddinput"  value="" placeholder="输入登录密码" dd-required type="password"></td>
                          </tr>
                          <tr height="40">
                            <td  height="35" align="left">说明</td></tr>
		<tr height="40">
                            <td align="left"><input id="remark" name="remark" class="ddinput" value="" placeholder="特别说明，没有请留空" type="text"></td>
                          </tr>
						  <tr height="40">
                            <td height="90" colspan="3" align="left">
<input type="hidden" name="act" value="tixian" /><input type="hidden" name="type" value="2" /><input type="hidden" name="sub" value="1" />
<input type="hidden" name="code_uid" value="<?=$dduser['code_uid']?>" /><input type="hidden" name="pwd" value="<?=$dduser['pwd']?>" />
<input type="submit" value="提 交"  class="register_dl"/></td>
                          </tr>
						   <?php }?>
      </table>
   </form>
</div>   </div>    

<?php include(TPLPATH.'/inc/footer.tpl.php');?>